<template>
	<view class="outer">
		<view class="tikuNum">题库{{tikuNum}}</view>
		<view v-for="item in questionBankList" :key="item.id">
			<view><text style="font-weight: bold;">题目：{{item.stem}}</text></view>
			<view class="opt">选项：{{item.option}}</view>
			<view class="opt">答案：{{item.answer}}</view>
			<view class="opt">分值：{{item.score}}</view>
		</view>
	</view>
</template>

<script>
	//查询题库
	import {questionBank} from '../../apis'
	export default{
		data(){
			return{
				questionBankList:[],
				tikuNum:0
			}
		},
		onLoad(option) {
			console.log(option)
			this.tikuNum = option.bankId
			questionBank({
				"bankId":option.bankId
			}).then((res)=>{
				let [err,data] = res
				console.log("题库内容"+data)
				this.questionBankList = data.data.data
			})
		},
		methods:{
			
		}
	}
</script>

<style lang="scss" scoped>
	.outer{
		width: 95%;
		padding-left: 10px;
		.tikuNum{
			text-align: center;
			font-size: 18px;
			font-weight: 900;
			padding: 10px;
		}
		.opt{
			padding-left: 10px;
		}
	}
</style>
